package com.invest.amplegest.xml.bean;

import javax.xml.bind.annotation.XmlAccessType;
import javax.xml.bind.annotation.XmlAccessorType;
import javax.xml.bind.annotation.XmlElement;
import javax.xml.bind.annotation.XmlRootElement;
import javax.xml.bind.annotation.XmlType;

@XmlRootElement(name = "aldo_field")
@XmlAccessorType(XmlAccessType.FIELD)
@XmlType(propOrder = {"number", "name", "techName",
		"mandatory", "numerical", "precision",
		"precisionComa", "value"})
public class AldoField {

	@XmlElement(name = "number")
	private int number;

	@XmlElement(name = "name")
	private String name;

	@XmlElement(name = "tech_name")
	private String techName;

	@XmlElement(name = "mandatory")
	private boolean mandatory;

	@XmlElement(name = "numerical")
	private boolean numerical;

	/*@XmlElement(name = "type")
	private AldoType type;*/

	@XmlElement(name = "precision")
	private int precision;

	@XmlElement(name = "precision_coma")
	private int precisionComa;

	@XmlElement(name = "value")
	private String value;


	public AldoField() { super(); }

	public AldoField(int number, String name, String techName,
			boolean mandatory, boolean numerical, int precision, int precisionComa,
			String value) {
		super();
		this.number = number;
		this.name = name;
		this.techName = techName;
		this.mandatory = mandatory;
		this.numerical = numerical;
		this.precision = precision;
		this.precisionComa = precisionComa;
		this.value = value;
	}


	public int getNumber() { return number; }
	public void setNumber(int number) { this.number = number; }

	public String getName() { return name; }
	public void setName(String name) { this.name = name; }

	public String getTechName() { return techName; }
	public void setTechName(String techName) { this.techName = techName; }

	public boolean isMandatory() { return mandatory; }
	public void setMandatory(boolean mandatory) { this.mandatory = mandatory; }

	public boolean isNumerical() { return numerical; }
	public void setNumerical(boolean numerical) { this.numerical = numerical; }

	public int getPrecision() { return precision; }
	public void setPrecision(int precision) { this.precision = precision; }

	public int getPrecisionComa() { return precisionComa; }
	public void setPrecisionComa(int precisionComa) { this.precisionComa = precisionComa; }

	public String getValue() { return value; }
	public void setValue(String value) { this.value = value; }


	@Override
	public String toString() { return value; }

}
